package jwj8508.j2ee.basic;

public class _07SungJukVO {
	private String name;
	private int kor;
	private int eng;
	private int mat;	
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public int getKor() {
		return kor;
	}
	public void setKor(int kor) {
		this.kor = kor;
	}
	public int getEng() {
		return eng;
	}
	public void setEng(int eng) {
		this.eng = eng;
	}
	public int getMat() {
		return mat;
	}
	public void setMat(int mat) {
		this.mat = mat;
	}
	public int getTot() {
		return kor + eng + mat;
	}	
	public float getAvg() {
		return getTot()/3F;
	}	
	public String getGrd() {
		String grd = "가";
		switch((int)getAvg()/10) {
			case 10: case 9: grd = "수"; break;
			case 8: grd = "우"; break;
			case 7: grd = "미"; break;
			case 6: grd = "양"; break;		
		}
		return grd;
	}	
}
